package meterMonitor.service;

import meterMonitor.mapper.ThTypeMaper;
import meterMonitor.model.ThTypePO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

@Service
@Transactional
public class ThTypeService {
    @Autowired
    private ThTypeMaper thTypeMaper;

    public void add(ThTypePO thType) {
        thTypeMaper.add(thType);
    }

    public void update(ThTypePO thType) {
        thTypeMaper.update(thType);
    }

    public void delete(Integer id) {
        thTypeMaper.deleteById(id);
    }

    public List<ThTypePO> queryList(ThTypePO thType) {
        return thTypeMaper.queryList(thType);
    }
}
